// MESSAGE RESERVE_DEBUG support class

#pragma once

namespace mavlink {
namespace fppa {
namespace msg {

/**
 * @brief RESERVE_DEBUG message
 *
 * reserve message of debug
 */
struct RESERVE_DEBUG : mavlink::Message {
    static constexpr msgid_t MSG_ID = 250;
    static constexpr size_t LENGTH = 32;
    static constexpr size_t MIN_LENGTH = 32;
    static constexpr uint8_t CRC_EXTRA = 183;
    static constexpr auto NAME = "RESERVE_DEBUG";


    float res1; /*<  res1. */
    float res2; /*<  res2. */
    float res3; /*<  res3. */
    float res4; /*<  res4. */
    uint32_t res5; /*<  res5. */
    uint32_t res6; /*<  res6. */
    int32_t res7; /*<  res7. */
    int32_t res8; /*<  res8. */


    inline std::string get_name(void) const override
    {
            return NAME;
    }

    inline Info get_message_info(void) const override
    {
            return { MSG_ID, LENGTH, MIN_LENGTH, CRC_EXTRA };
    }

    inline std::string to_yaml(void) const override
    {
        std::stringstream ss;

        ss << NAME << ":" << std::endl;
        ss << "  res1: " << res1 << std::endl;
        ss << "  res2: " << res2 << std::endl;
        ss << "  res3: " << res3 << std::endl;
        ss << "  res4: " << res4 << std::endl;
        ss << "  res5: " << res5 << std::endl;
        ss << "  res6: " << res6 << std::endl;
        ss << "  res7: " << res7 << std::endl;
        ss << "  res8: " << res8 << std::endl;

        return ss.str();
    }

    inline void serialize(mavlink::MsgMap &map) const override
    {
        map.reset(MSG_ID, LENGTH);

        map << res1;                          // offset: 0
        map << res2;                          // offset: 4
        map << res3;                          // offset: 8
        map << res4;                          // offset: 12
        map << res5;                          // offset: 16
        map << res6;                          // offset: 20
        map << res7;                          // offset: 24
        map << res8;                          // offset: 28
    }

    inline void deserialize(mavlink::MsgMap &map) override
    {
        map >> res1;                          // offset: 0
        map >> res2;                          // offset: 4
        map >> res3;                          // offset: 8
        map >> res4;                          // offset: 12
        map >> res5;                          // offset: 16
        map >> res6;                          // offset: 20
        map >> res7;                          // offset: 24
        map >> res8;                          // offset: 28
    }
};

} // namespace msg
} // namespace fppa
} // namespace mavlink
